-- GENERATED SPELL FOR [Mistress of Doom] --


function spell0_19192(pUnit, Event) --@Rain of Chaos,n/a--
pUnit:FullCastSpellOnTarget(34017,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_19192', 9000, 1)
end

function spell1_19192(pUnit, Event) --@Summon Imps,Self--
pUnit:FullCastSpellOnTarget(34237,pUnit)
pUnit:RegisterEvent('Sorts_19192', 595, 1)
end

function Sorts_19192(pUnit, Event)
local choix_sorts_19192 = math.random(0, 1)
if choix_sorts_19192 == 0 then
pUnit:RegisterEvent('spell0_19192', 1, 1)
end
if choix_sorts_19192 == 1 then
pUnit:RegisterEvent('spell1_19192', 1, 1)
end
end

function mob19192_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_19192', math.random(1500, 3000), 1)
end

function mob19192_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob19192_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob19192_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(19192, 1, 'mob19192_Action')
RegisterUnitEvent(19192, 2, 'mob19192_Leave')
RegisterUnitEvent(19192, 3, 'mob19192_Kill')
RegisterUnitEvent(19192, 4, 'mob19192_Die')
